
 console.log(`修改商品状态`);
 let body = $response.body;
 body =  JSON.parse(body);
 if (body.data.tradeConfirmation.unavailableItems.length>0){
    console.log(`修改为有库存状态`);
    body.data.displayConfig.forbidPay = false
    body.data.displayConfig.yzGuarantee = true
    new_item = body.data.tradeConfirmation.unavailableItems[0]
    new_item.stockNum = 10
    new_item.virtualType = 0
    new_item.availableNum = 2
    new_item.buyedNum = 0
    new_item.sku =  JSON.parse(new_item.sku)
    body.data.tradeConfirmation.orderItems.push(new_item)
    body.data.tradeConfirmation.unavailableItems.pop(body.data.tradeConfirmation.unavailableItems[0])
     
 }
 body =  JSON.stringify(body);
 $done({ body })